From 3a3589c07ab6cb3cbfd17215f32f3178e02c4939 Mon Sep 17 00:00:00 2001 From: Juanma Barranquero Date: Tue, 5 Jun 2007 10:12:37 +0000 Subject: [PATCH] (face-id): If the argument is a face alias, return the ID of the target face. --- lisp/faces.el | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/lisp/faces.el b/lisp/faces.el index a8c92ab9a75..048dae039ad 100644 --- a/lisp/faces.el +++ b/lisp/faces.el @@ -222,11 +222,12 @@ Value is FACE." (defun face-id (face &optional frame) "Return the internal ID of face with name FACE. +If FACE is a face-alias, return the ID of the target face. The optional argument FRAME is ignored, since the internal face ID of a face name is the same for all frames." (check-face face) - (get face 'face)) - + (or (get face 'face) + (face-id (get face 'face-alias)))) (defun face-equal (face1 face2 &optional frame) "Non-nil if faces FACE1 and FACE2 are equal. -- 2.30.2